void plotGr()
{
  char GIFNAME[50];
  TCanvas* c_angle = new TCanvas();
  c_angle->Divide(1,2);
  c_angle->cd(1);
  
  angle_all_dump->SetLineColor(1);
  angle_TB_acc_dump->SetLineColor(2);
  angle_TTBB_acc_dump->SetLineColor(3);
  angle_LR_acc_dump->SetLineColor(4);
  angle_TBRevH1LR0_acc_dump->SetLineColor(5);
  angle_TBRevH1LR1_acc_dump->SetLineColor(6);
    
  angle_all_dump->Draw();
  angle_TB_acc_dump->Draw("same");
  angle_TTBB_acc_dump->Draw("same");  
  angle_LR_acc_dump->Draw("same");
  angle_TBRevH1LR0_acc_dump->Draw("same");
  angle_TBRevH1LR1_acc_dump->Draw("same");
  
  c_angle->cd(2);
  angle_all_target->SetLineColor(1);
  angle_TB_acc_target->SetLineColor(2);
  angle_TTBB_acc_target->SetLineColor(3);
  angle_LR_acc_target->SetLineColor(4);
  angle_TBRevH1LR0_acc_target->SetLineColor(5);
  angle_TBRevH1LR1_acc_target->SetLineColor(6);  

  angle_all_target->Draw();
  angle_TB_acc_target->Draw("same");
  angle_TTBB_acc_target->Draw("same");
  angle_LR_acc_target->Draw("same");
  angle_TBRevH1LR0_acc_target->Draw("same");
  angle_TBRevH1LR1_acc_target->Draw("same");  

  sprintf(GIFNAME,"result.ps(");
  c_angle->SaveAs(GIFNAME);

  TCanvas* c_mass = new TCanvas();
  c_mass->Divide(1,2);
  c_mass->cd(1);
  
  mass_all_dump->SetLineColor(1);
  mass_TB_acc_dump->SetLineColor(2);
  mass_TTBB_acc_dump->SetLineColor(3);
  mass_LR_acc_dump->SetLineColor(4);
  mass_TBRevH1LR0_acc_dump->SetLineColor(5);
  mass_TBRevH1LR1_acc_dump->SetLineColor(6);
    
  mass_all_dump->Draw();
  mass_TB_acc_dump->Draw("same");
  mass_TTBB_acc_dump->Draw("same");  
  mass_LR_acc_dump->Draw("same");
  mass_TBRevH1LR0_acc_dump->Draw("same");
  mass_TBRevH1LR1_acc_dump->Draw("same");
  
  c_mass->cd(2);
  mass_all_target->SetLineColor(1);
  mass_TB_acc_target->SetLineColor(2);
  mass_TTBB_acc_target->SetLineColor(3);
  mass_LR_acc_target->SetLineColor(4);
  mass_TBRevH1LR0_acc_target->SetLineColor(5);
  mass_TBRevH1LR1_acc_target->SetLineColor(6);  

  mass_all_target->Draw();
  mass_TB_acc_target->Draw("same");
  mass_TTBB_acc_target->Draw("same");
  mass_LR_acc_target->Draw("same");
  mass_TBRevH1LR0_acc_target->Draw("same");
  mass_TBRevH1LR1_acc_target->Draw("same");  

  sprintf(GIFNAME,"result.ps");
  c_mass->SaveAs(GIFNAME);

  TLegend *legend=new TLegend(0.6,0.65,0.88,0.85);
  legend->SetTextFont(72);
  legend->SetTextSize(0.04);
  legend->AddEntry(mass_all_target,"All","l");
  legend->AddEntry(mass_TB_acc_target,"L1 by TB","l");
  legend->AddEntry(mass_TTBB_acc_target,"each raod on T and B","l");
  legend->AddEntry(mass_LR_acc_target,"L R at H234","l");
  legend->AddEntry(mass_TBRevH1LR0_acc_target,"TB Rev H1 shift 0","l");
  legend->AddEntry(mass_TBRevH1LR1_acc_target,"TB Rev H1 shift 1","l");
  legend->Draw();


 
  TCanvas* c_MassTB1TBRevH1LR0 = new TCanvas();
  TH1D* mass_divide = new TH1D("mass_divide", "mass_divide", 100, 1, 10);
  mass_divide->Add(mass_TB_acc_target, mass_TBRevH1LR0_acc_target, 1, -1);
  mass_divide->Draw();

  TCanvas* c_xF = new TCanvas();
  c_xF->Divide(1,2);
  c_xF->cd(1);
  
  xF_all_dump->SetLineColor(1);
  xF_TB_acc_dump->SetLineColor(2);
  xF_TTBB_acc_dump->SetLineColor(3);
  xF_LR_acc_dump->SetLineColor(4);
  xF_TBRevH1LR0_acc_dump->SetLineColor(5);
  xF_TBRevH1LR1_acc_dump->SetLineColor(6);
    
  xF_all_dump->Draw();
  xF_TB_acc_dump->Draw("same");
  xF_TTBB_acc_dump->Draw("same");  
  xF_LR_acc_dump->Draw("same");
  xF_TBRevH1LR0_acc_dump->Draw("same");
  xF_TBRevH1LR1_acc_dump->Draw("same");
  
  c_xF->cd(2);
  xF_all_target->SetLineColor(1);
  xF_TB_acc_target->SetLineColor(2);
  xF_TTBB_acc_target->SetLineColor(3);
  xF_LR_acc_target->SetLineColor(4);
  xF_TBRevH1LR0_acc_target->SetLineColor(5);
  xF_TBRevH1LR1_acc_target->SetLineColor(6);  

  xF_all_target->Draw();
  xF_TB_acc_target->Draw("same");
  xF_TTBB_acc_target->Draw("same");
  xF_LR_acc_target->Draw("same");
  xF_TBRevH1LR0_acc_target->Draw("same");
  xF_TBRevH1LR1_acc_target->Draw("same");  

  sprintf(GIFNAME,"result.ps");
  c_xF->SaveAs(GIFNAME);


  TCanvas* c_z = new TCanvas();


  
  z_all_dump->SetLineColor(1);
  z_TB_acc_dump->SetLineColor(2);
  z_TTBB_acc_dump->SetLineColor(3);
  z_LR_acc_dump->SetLineColor(4);
  z_TBRevH1LR0_acc_dump->SetLineColor(5);
  z_TBRevH1LR1_acc_dump->SetLineColor(6);
    
  z_all_dump->Draw();
  z_TB_acc_dump->Draw("same");
  z_TTBB_acc_dump->Draw("same");  
  z_LR_acc_dump->Draw("same");
  z_TBRevH1LR0_acc_dump->Draw("same");
  z_TBRevH1LR1_acc_dump->Draw("same");
  

  z_all_target->SetLineColor(1);
  z_TB_acc_target->SetLineColor(2);
  z_TTBB_acc_target->SetLineColor(3);
  z_LR_acc_target->SetLineColor(4);
  z_TBRevH1LR0_acc_target->SetLineColor(5);
  z_TBRevH1LR1_acc_target->SetLineColor(6);  

  z_all_target->Draw("same");
  z_TB_acc_target->Draw("same");
  z_TTBB_acc_target->Draw("same");
  z_LR_acc_target->Draw("same");
  z_TBRevH1LR0_acc_target->Draw("same");
  z_TBRevH1LR1_acc_target->Draw("same");  

  sprintf(GIFNAME,"result.ps)");
  c_z->SaveAs(GIFNAME);

 
}
